﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<dynamic>" %>

<%@ Import Namespace="ElectronicRecords.Models" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
    <%=ViewData["Title"] %>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <form id="form1" runat="server">
    <h2>
        <center><%=ViewData["Title"] %><br /></center><br />
        <%=Html.ActionLink("Создать", "Create", new { }, new {@class="g-button" })%>&nbsp&nbsp&nbsp   <%=Html.ActionLink("Найти", "Find", new { }, new { @class = "g-button" })%>
        
    </h2>
    <table id="maintable" >
        <tr>
            <th style="width:10%" >
                Действие
            </th>
            <th style="width:10%">
                ID
            </th>
            <th style="width:40%">
                Фамилия
            </th>
            <th style="width:40%">
                Имя
            </th>
        </tr>
        <% foreach (Clients c in (IEnumerable<Clients>)ViewData["Clients"])
           {%>
        <tr>
            <td>
                
                <a href= "Client/<%=c.ID_Client %>"><img height="24" width="24" src="../../img/sherlock.png" ></a>
                <a href= "Edit/<%=c.ID_Client %>"><img height="24" width="24"  src="../../img/textedit.png" ></a>
            </td>
            <td>
                <%=c.ID_Client %>
            </td>
            <td>
                <%=c.Firstname %>
            </td>
            <td>
                <%=c.Lastname %>
            </td>
        </tr>
        <%} %>
    </table>
    </form>
</asp:Content>
